import java.util.Scanner;

public class n32 {
	public static void main(String[] args) {		
		Scanner scn = new Scanner(System.in);
		System.out.print("Vvedite dlinu massiva ");
		int i = scn.nextInt();		
		int array[] = new int[i];
		for (int j = 0; j < i; j++) {
			array[j] = j+1;
			if ((j+1)%3 == 0) {
				System.out.println("Chislo " + array[j] + " kratno 3");
			}
		}
	}
}
